//
// Created by Tony on 2024/8/3.
//

#ifndef PARSER_CLASS_MODULE_H
#define PARSER_CLASS_MODULE_H

#include "../../AstList.h"
#include "../stmt/ImportStmt.h"
#include "ClassDefine.h"
#include <cstdint>

namespace Parser {

class ClassModule final : public AstList {
    string nodeName;
    vector<shared_ptr<ImportStmt>> mImports;
    vector<shared_ptr<ClassDefine>> mClassDefines;

public:
    ClassModule() : AstList({}) { nodeName = __func__; }

    void addImport(shared_ptr<ImportStmt> import);
    vector<shared_ptr<ImportStmt>> getImports();

    void addClassDefine(shared_ptr<ClassDefine> classDefine);
    vector<shared_ptr<ClassDefine>> getClassDefines();

    int32_t accept(Compiler::Visitor* visitor) override;
};

} // namespace Parser

#endif // PARSER_CLASS_MODULE_H
